DEPTH = ../..

include $(DEPTH)/scripts/Makefile

PROGRAM     = ApacheLogViewer
SRCS        = $(PROGRAM).cxx
LIBS        = -lTimestamp

DATABASE    = ../ApacheLogLoader/ApacheLog.db

demo: clean all runDemo

runDemo: 
	@$(SCRIPTS_DIR)/progress 'Run Demo'
	./$(PROGRAM) $(DATABASE)

debugDemo:
	@$(SCRIPTS_DIR)/progress 'Run Demo'
	@echo "Type 'run $(DATABASE)
	gdb ./$(PROGRAM)

all: $(PROGRAM)

$(PROGRAM): $(SRCS)
	@$(SCRIPTS_DIR)/progress 'Building Demo'
	@$(GPP) $(CFLAGS) $? $(LDFLAGS) $(LIBS) -o $@

clean: 
	@$(SCRIPTS_DIR)/progress 'Cleaning'
	@rm -f $(PROGRAM)
